\select@language {english}
\select@language {portuguese}
\contentsline {chapter}{\numberline {1}Introdu\c c\~ao}{1}
\contentsline {section}{\numberline {1.1}Objetivo}{2}
\contentsline {section}{\numberline {1.2}Estrutura da Monografia}{2}
\contentsline {chapter}{\numberline {2}Trabalhos Relacionados}{3}
\contentsline {section}{\numberline {2.1}Utiliza\c c\~ao da T\'ecnica de \emph {Chroma-Key} para Composi\c c\~ao de Cenas em Ambientes de Realidade Aumentada}{3}
\contentsline {section}{\numberline {2.2}An\'alise de Algoritmos para \emph {Chroma-Key}}{4}
\contentsline {section}{\numberline {2.3}\emph {Chroma-Key} Aplicado a Ambientes 3D}{4}
\contentsline {section}{\numberline {2.4}Segmenta\c c\~ao de imagens multiespectrais baseada na componente matriz de transforma\c c\~ao HSV}{5}
\contentsline {section}{\numberline {2.5}Rastreamento de Zoom de C\^amera}{5}
\contentsline {section}{\numberline {2.6}M-FIT: Editora\c c\~ao Eletr\^onica de V\IeC {\'\i }deos com Detec\c c\~ao de Transi\c c\~oes}{6}
\contentsline {section}{\numberline {2.7}Detec\c c\~ao de Posicionamento de Motoristas de Ve\IeC {\'\i }culos}{6}
\contentsline {section}{\numberline {2.8}Cenarios Virtuais com um Estudo de Sincronismo de C\^amera}{7}
\contentsline {chapter}{\numberline {3}Conceitos Fundamentais }{8}
\contentsline {section}{\numberline {3.1}\emph {Chroma-Key}}{8}
\contentsline {section}{\numberline {3.2}Cor}{12}
\contentsline {subsection}{\numberline {3.2.1}Representa\c c\~ao CIE-RGB}{12}
\contentsline {subsection}{\numberline {3.2.2}Lumin\^ancia e Cromin\^ancia}{13}
\contentsline {subsection}{\numberline {3.2.3}Sistema RGB}{14}
\contentsline {subsection}{\numberline {3.2.4}Sistema HSV}{15}
\contentsline {section}{\numberline {3.3}Segmenta\c c\~ao de Imagens}{16}
\contentsline {subsection}{\numberline {3.3.1}Identifica\c c\~ao de segmentos}{16}
\contentsline {subsection}{\numberline {3.3.2}Detec\c c\~ao de descontinuidades}{16}
\contentsline {subsubsection}{\numberline {3.3.2.1}Detec\c c\~ao de pontos}{17}
\contentsline {subsubsection}{\numberline {3.3.2.2}Detec\c c\~ao de linhas}{18}
\contentsline {subsubsection}{\numberline {3.3.2.3}Detec\c c\~ao de bordas}{18}
\contentsline {subsection}{\numberline {3.3.3}Detec\c c\~ao de Similaridades}{19}
\contentsline {subsubsection}{\numberline {3.3.3.1}\emph {Threshold}}{20}
\contentsline {subsubsection}{\numberline {3.3.3.2}Crescimento de regi\~ao}{20}
\contentsline {section}{\numberline {3.4}Processamento de Imagem}{20}
\contentsline {subsection}{\numberline {3.4.1}Realce de Imagem}{21}
\contentsline {subsection}{\numberline {3.4.2}M\'etodos ponto por ponto}{22}
\contentsline {subsubsection}{\numberline {3.4.2.1}Histograma}{22}
\contentsline {subsubsection}{\numberline {3.4.2.2}Equaliza\c c\~ao}{23}
\contentsline {subsubsection}{\numberline {3.4.2.3}Especifica\c c\~ao do Histograma}{24}
\contentsline {subsection}{\numberline {3.4.3}Aprimoramento local}{24}
\contentsline {subsection}{\numberline {3.4.4}M\'etodos de Vizinhan\c ca }{25}
\contentsline {subsection}{\numberline {3.4.5}Filtragem Passa Baixa}{25}
\contentsline {subsection}{\numberline {3.4.6}Filtro Passa Alta}{25}
\contentsline {subsection}{\numberline {3.4.7}Filtros n\~ao Lineares}{26}
\contentsline {subsection}{\numberline {3.4.8}Filtro Mediana}{26}
\contentsline {section}{\numberline {3.5}Transforma\c c\~oes 2D}{27}
\contentsline {subsection}{\numberline {3.5.1}Transforma\c c\~oes 2D em Coordenadas Homog\^eneas}{30}
\contentsline {section}{\numberline {3.6}Calibra\c c\~ao de C\^amera}{32}
\contentsline {subsection}{\numberline {3.6.1}Modelo de \emph {Pinhole}}{32}
\contentsline {section}{\numberline {3.7}Realidade Aumentada}{34}
\contentsline {subsection}{\numberline {3.7.1}Requerimentos}{37}
\contentsline {section}{\numberline {3.8}Sombra}{38}
\contentsline {subsection}{\numberline {3.8.1}Algoritmos: Atributos da Sombra}{40}
\contentsline {subsubsection}{\numberline {3.8.1.1}\emph {Shadow map}}{40}
\contentsline {section}{\numberline {3.9}OpenCV}{41}
\contentsline {section}{\numberline {3.10}Qt}{42}
\contentsline {chapter}{\numberline {4}Metodologia}{44}
\contentsline {section}{\numberline {4.1}Camada Manual}{44}
\contentsline {subsection}{\numberline {4.1.1}Entradas \emph {On-Line} ou \emph {Off-Line}}{46}
\contentsline {section}{\numberline {4.2}Manipula\c c\~ao do Objeto de Interesse}{46}
\contentsline {section}{\numberline {4.3}Camada Autom\'atica}{47}
\contentsline {section}{\numberline {4.4}V\IeC {\'\i }deo em ambiente monocrom\'atico e personagem de interesse}{48}
\contentsline {section}{\numberline {4.5}V\IeC {\'\i }deo com cen\'ario de interesse}{49}
\contentsline {section}{\numberline {4.6}Aplica\c c\~ao da t\'ecnica de \emph {Chroma-Key}}{49}
\contentsline {subsection}{\numberline {4.6.1}Segmenta\c c\~ao de imagem}{51}
\contentsline {subsection}{\numberline {4.6.2}Combina\c c\~ao de imagens}{51}
\contentsline {section}{\numberline {4.7}Realidade Aumentada}{53}
\contentsline {subsection}{\numberline {4.7.1}Calibra\c c\~ao de C\^amera}{53}
\contentsline {subsection}{\numberline {4.7.2}\emph {Zoom-In} e \emph {Zoom-Out}}{53}
\contentsline {subsection}{\numberline {4.7.3}Texturiza\c c\~ao}{54}
\contentsline {subsection}{\numberline {4.7.4}Sombras}{54}
\contentsline {chapter}{\numberline {5}An\'alise de Requisitos}{56}
\contentsline {section}{\numberline {5.1}Requisitos Funcionais}{56}
\contentsline {subsection}{\numberline {5.1.1}Requisitos de Neg\'ocio}{56}
\contentsline {subsubsection}{\numberline {5.1.1.1}Aplica\c c\~ao da t\'ecnica de \emph {Chroma-Key}}{56}
\contentsline {subsubsection}{\numberline {5.1.1.2}Utiliza\c c\~ao de v\IeC {\'\i }deos \emph {On-Line} e \emph {Off-Line}}{56}
\contentsline {subsection}{\numberline {5.1.2}Requisitos de Usu\'ario}{56}
\contentsline {subsubsection}{\numberline {5.1.2.1}Controles de grava\c c\~ao e reprodu\c c\~ao dos v\IeC {\'\i }deos}{56}
\contentsline {subsubsection}{\numberline {5.1.2.2}Sele\c c\~ao dos tipos de entrada de v\IeC {\'\i }deo}{57}
\contentsline {subsubsection}{\numberline {5.1.2.3}Redimensionamento e deslocamento do objeto ou personagem de interesse}{57}
\contentsline {subsubsection}{\numberline {5.1.2.4}\emph {Timeline} - Linha de tempo dos v\IeC {\'\i }deos }{57}
\contentsline {subsubsection}{\numberline {5.1.2.5}Pr\'e-visualiza\c c\~ao dos \emph {frames}}{57}
\contentsline {subsection}{\numberline {5.1.3}Requisitos de Sistema}{57}
\contentsline {subsubsection}{\numberline {5.1.3.1}Integra\c c\~ao ao M-FIT}{57}
\contentsline {subsubsection}{\numberline {5.1.3.2}Manipula\c c\~ao de arquivos}{57}
\contentsline {subsubsection}{\numberline {5.1.3.3}Arquivos de v\IeC {\'\i }deo suportados}{58}
\contentsline {subsubsection}{\numberline {5.1.3.4}Compatibilidade com \emph {hardwares} externos}{58}
\contentsline {subsubsection}{\numberline {5.1.3.5}Aplica\c c\~ao de efeitos visuais}{58}
\contentsline {subsubsection}{\numberline {5.1.3.6}Biblioteca OpenCV}{58}
\contentsline {subsubsection}{\numberline {5.1.3.7}QT}{58}
\contentsline {section}{\numberline {5.2}Requisitos N\~ao Funcionais}{58}
\contentsline {subsection}{\numberline {5.2.1}Requisitos de Usu\'ario}{58}
\contentsline {subsection}{\numberline {5.2.2}Requisitos de Sistema}{59}
\contentsline {section}{\numberline {5.3}Restri\c c\~oes}{59}
\contentsline {chapter}{\numberline {6}An\'alise e Modelagem}{60}
\contentsline {section}{\numberline {6.1}Diagramas de Casos de Uso}{60}
\contentsline {subsection}{\numberline {6.1.1}Cen\'ario Geral}{60}
\contentsline {subsection}{\numberline {6.1.2}Cen\'ario Selecionar V\IeC {\'\i }deos de Entrada}{60}
\contentsline {subsubsection}{\numberline {6.1.2.1}Caso de Uso UC01 - Selecionar V\IeC {\'\i }deo com Objeto de Interesse}{60}
\contentsline {subsubsection}{\numberline {6.1.2.2}Caso de Uso UC02 - Selecionar V\IeC {\'\i }deo com Cen\'ario ou \emph {Background} de Interesse}{63}
\contentsline {subsubsection}{\numberline {6.1.2.3}Caso de Uso UC03 - Selecionar Tipo de Entrada do V\IeC {\'\i }deo}{63}
\contentsline {subsubsection}{\numberline {6.1.2.4}Caso de Uso UC04 - Selecionar C\^amera de Entrada}{64}
\contentsline {subsubsection}{\numberline {6.1.2.5}Caso de Uso UC05 - Informar o diret\'orio do v\IeC {\'\i }deo}{64}
\contentsline {subsection}{\numberline {6.1.3}Cen\'ario Manipular o objeto de interesse}{65}
\contentsline {subsubsection}{\numberline {6.1.3.1}Caso de Uso UC06 - Reposicionar Objeto de Interesse}{65}
\contentsline {subsubsection}{\numberline {6.1.3.2}Caso de Uso UC07 - Redimensionar Objeto de Interesse}{67}
\contentsline {subsection}{\numberline {6.1.4}Cen\'ario Manipular v\IeC {\'\i }deo resultante}{68}
\contentsline {subsubsection}{\numberline {6.1.4.1}Caso de Uso UC08 - Iniciar Grava\c c\~ao}{69}
\contentsline {subsubsection}{\numberline {6.1.4.2}Caso de Uso UC09 - Iniciar Reprodu\c c\~ao de V\IeC {\'\i }deo Off-Line}{69}
\contentsline {subsubsection}{\numberline {6.1.4.3}Caso de Uso UC10 - Finalizar Grava\c c\~ao}{70}
\contentsline {subsubsection}{\numberline {6.1.4.4}Caso de Uso UC11 - Finalizar Reprodu\c c\~ao de V\IeC {\'\i }deo Off-Line}{71}
\contentsline {subsubsection}{\numberline {6.1.4.5}Caso de Uso UC12 - Salvar Grava\c c\~ao}{71}
\contentsline {subsubsection}{\numberline {6.1.4.6}Caso de Uso UC13 - Informar o diret\'orio destino}{72}
\contentsline {subsubsection}{\numberline {6.1.4.7}Caso de Uso UC14 - Visualizar Grava\c c\~ao}{72}
\contentsline {section}{\numberline {6.2}Diagrama de Classes}{73}
\contentsline {subsection}{\numberline {6.2.1}Classe: jcChromaKey}{73}
\contentsline {subsection}{\numberline {6.2.2}Classe: jcTransformador}{75}
\contentsline {subsection}{\numberline {6.2.3}Classe: jcTratadorDeBorda}{75}
\contentsline {subsection}{\numberline {6.2.4}Classe: jcPintor}{75}
\contentsline {subsection}{\numberline {6.2.5}Classe: jcVideo}{76}
\contentsline {subsection}{\numberline {6.2.6}Classe: jcProcessadorDeImagem}{78}
\contentsline {subsection}{\numberline {6.2.7}Classe: jcSegmentador}{80}
\contentsline {subsection}{\numberline {6.2.8}Classe: jcHistograma}{81}
\contentsline {subsection}{\numberline {6.2.9}Classe: jcLog}{82}
\contentsline {subsection}{\numberline {6.2.10}Classe: jcProjeto}{82}
\contentsline {subsection}{\numberline {6.2.11}Classe: jcMorfadorMat}{83}
\contentsline {subsection}{\numberline {6.2.12}Classe: jcTocadorDeVideo}{83}
\contentsline {subsection}{\numberline {6.2.13}Classe: jcXml}{84}
\contentsline {subsection}{\numberline {6.2.14}Classe: jcTextura}{85}
\contentsline {subsection}{\numberline {6.2.15}Classe: jcSombreador}{85}
\contentsline {subsection}{\numberline {6.2.16}Classe: jcZoom}{86}
\contentsline {subsection}{\numberline {6.2.17}Classe: jcInterface}{86}
\contentsline {subsection}{\numberline {6.2.18}Classe: jcLimiar}{87}
\contentsline {section}{\numberline {6.3}Diagramas de Sequ\^encias}{87}
\contentsline {subsection}{\numberline {6.3.1}Sequ\^encia: Geral}{88}
\contentsline {subsection}{\numberline {6.3.2}Sequ\^encia: Segmenta\c c\~ao do Objeto de Interesse}{88}
\contentsline {subsection}{\numberline {6.3.3}Sequ\^encia: T\'ecnica de \emph {Chroma-Key}}{88}
\contentsline {subsection}{\numberline {6.3.4}Sequ\^encia: Tratamento de Borda do Objeto de Interesse}{91}
\contentsline {subsection}{\numberline {6.3.5}Sequ\^encia: Texturiza\c c\~ao}{93}
\contentsline {subsection}{\numberline {6.3.6}Sequ\^encia: Zoom}{94}
\contentsline {section}{\numberline {6.4}Diagramas de Estados}{95}
\contentsline {subsection}{\numberline {6.4.1}Estado: On-Line 1 - Fundo Monocrom\'atico e Objeto de Interesse}{95}
\contentsline {subsubsection}{\numberline {6.4.1.1}Obtendo \emph {Frame} com Objeto de Interesse}{95}
\contentsline {subsection}{\numberline {6.4.2}Estado: Obten\c c\~ao de Padr\~ao do Objeto, Imagem e Fundo}{95}
\contentsline {subsubsection}{\numberline {6.4.2.1}Padronizando o Fundo e Objeto}{95}
\contentsline {subsubsection}{\numberline {6.4.2.2}Padronizando Imagem}{95}
\contentsline {subsection}{\numberline {6.4.3}Estado: Ambiente - Imagem de Interesse}{97}
\contentsline {subsection}{\numberline {6.4.4}Estado: On-Line 2}{97}
\contentsline {subsubsection}{\numberline {6.4.4.1}Obtendo \emph {Frame} Com Ambiente Filmado}{97}
\contentsline {subsection}{\numberline {6.4.5}Estado: \emph {Off-Line}}{97}
\contentsline {subsubsection}{\numberline {6.4.5.1}Buscando V\IeC {\'\i }deo}{97}
\contentsline {subsubsection}{\numberline {6.4.5.2}Carregando V\IeC {\'\i }deo}{97}
\contentsline {subsubsection}{\numberline {6.4.5.3}Obtendo \emph {Frame} com a Imagem de Interesse}{98}
\contentsline {subsection}{\numberline {6.4.6}Estado: \emph {Zoom-In} e \emph {Zoom-Out}}{98}
\contentsline {subsubsection}{\numberline {6.4.6.1}Calculando Propor\c c\~oes}{98}
\contentsline {subsection}{\numberline {6.4.7}Estado: T\'ecnica de \emph {Chroma-Key}}{98}
\contentsline {subsubsection}{\numberline {6.4.7.1}Extraindo Objeto}{98}
\contentsline {subsubsection}{\numberline {6.4.7.2}Transformando Objeto}{98}
\contentsline {subsubsection}{\numberline {6.4.7.3}Transformando Imagem}{98}
\contentsline {subsubsection}{\numberline {6.4.7.4}Compondo Objeto e Imagem}{99}
\contentsline {subsection}{\numberline {6.4.8}Estado: Realidade Aumentada}{99}
\contentsline {subsection}{\numberline {6.4.9}Estado: Texturiza\c c\~ao}{99}
\contentsline {subsubsection}{\numberline {6.4.9.1}Suavizando as Cores do Objeto e Imagem}{99}
\contentsline {subsection}{\numberline {6.4.10}Estado: Tratamento de Bordas}{99}
\contentsline {subsubsection}{\numberline {6.4.10.1}Detectando Bordas}{99}
\contentsline {subsubsection}{\numberline {6.4.10.2}Tratando as Bordas do Objeto}{100}
\contentsline {subsection}{\numberline {6.4.11}Estado: Sombra}{100}
\contentsline {subsubsection}{\numberline {6.4.11.1}Detectando Bordas do Objeto}{100}
\contentsline {subsubsection}{\numberline {6.4.11.2} Detectando Ponto de Ilumina\c c\~ao}{100}
\contentsline {subsubsection}{\numberline {6.4.11.3}Criando Sombra do Objeto}{100}
